<template>
  <div class="container">
    <CategoryVue title="游戏">
      <template scope="azhan">
        {{ azhan }}
        <ul>
          <li v-for="(g, index) in azhan.games" :key="index">{{ g }}</li>
        </ul>
      </template>
    </CategoryVue>

    <CategoryVue title="游戏">
      <!-- 
            es6解构赋值
                {games}
       -->
      <template scope="{games}">
        <ol>
          <li v-for="(g, index) in games" :key="index">
            {{ g }}
          </li>
        </ol>
      </template>
    </CategoryVue>

    <CategoryVue title="游戏">
      <template scope="azhan">
        <h4 v-for="(g, index) in azhan.games" :key="index">{{ g }}</h4>
      </template>
    </CategoryVue>
  </div>
</template>

<script>
import CategoryVue from "./components/CategoryVue.vue";
export default {
  name: "App",
  components: { CategoryVue },
};
</script>
<style>
.container,
.foot {
  display: flex;
  justify-content: space-around;
}
h4 {
  text-align: center;
}
</style>